
package com.qkjia.rabbitmq.listener;

import org.springframework.amqp.core.Message;
import org.springframework.amqp.core.MessageListener;

public class SpringQueueListener  implements MessageListener {
    @Override
    public void onMessage(Message message) {

        try {
            System.out.println(new String(message.getBody(), "UTF-8"));
        } catch (Exception e) {
            e.printStackTrace();
        }

    }
}